<admintpl file="header" />
</head>
<body>
	<div class="wrap js-check-wrap">
		<ul class="nav nav-tabs">
			<li class="active"><a href="#">提现申请</a></li>
		</ul>
        <form class="well form-search" method="post" action="{:U('Business/getBalances')}">
            商户名:
            <input type="text" name="business_name" style="width: 100px;" value="{:I('request.business_name/s','')}" placeholder="请输入商户名">
            收款人姓名:
            <input type="text" name="name" style="width: 100px;" value="{:I('request.name/s','')}" placeholder="请输入收款人姓名">
            是否打款:
            <php>$is_solved_type=I('is_solved');</php>
            <select name="is_solved" style="width: 100px;" >
                <option value="99">全部</option>
                <option value="0" <php>if($is_solved_type==='0'){echo 'selected';}</php> >未打款</option>
                <option value="1" <php>if($is_solved_type==1){echo 'selected';}</php> >已打款</option>
            </select>
            <input type="submit" class="btn btn-primary" value="搜索" id="sou"/>
            <a class="btn btn-danger" href="{:U('Business/getBalances')}">清空</a>
        </form>
		<php>$business_type=array("1"=>'商户',"2"=>'技师');</php>
		<php>$type=array("1"=>'银行卡',"2"=>'支付宝');</php>
		<php>$is_solved=array("1"=>'已打款',"0"=>'未打款');</php>
		<form method="post" class="js-ajax-form">
			<table class="table table-hover table-bordered table-list">
				<thead>
					<tr>
						<th width="50">ID</th>
						<th>收款人姓名</th>
						<th>收款人电话</th>
						<th>账号</th>
						<th>开户行</th>
						<th>提现类型</th>
						<th>提交时间</th>
						<th>提现金额</th>
						<th>是否打款</th>
						<th>商户名</th>
						<th>商户类型</th>
						<th width="120">{:L('ACTIONS')}</th>
					</tr>
				</thead>
				<tbody>
					<foreach name="balances" item="vo">
					<tr>
						<td>{$vo.id}</td>
						<td>{$vo.name}</td>
						<td>{$vo.phone}</td>
						<td>{$vo.account}</td>
						<td>{$vo.bank}</td>
                        <td>{$type[$vo['type']]}</td>
						<td>{$vo.create_time|date="Y-m-d",###}</td>
						<td>{$vo.price}</td>
						<td>{$is_solved[$vo['is_solved']]}</td>
						<td>{$vo.business_name}</td>
						<td>{$business_type[$vo['business_type']]}</td>
						<td>
                            <a href="{:U('Business/balanceSolve',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="确认打款了么？">确认打款</a> |
							<a href="{:U('Business/balanceDelete',array('id'=>$vo['id']))}" class="js-ajax-dialog-btn" data-msg="确认删除么？">删除</a>
						</td>
					</tr>
					</foreach>
				</tbody>
			</table>
		</form>
		<div class="pagination">{$page}</div>
	</div>
	<script src="__PUBLIC__/js/common.js"></script>
</body>
</html>